package cn.gov.ssxmzj.controller;

import cn.gov.ssxmzj.entry.Result;
import cn.gov.ssxmzj.service.OptionService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.ResponseBody;

@Controller
@RequestMapping("/option")
public class OptionController {

    @Autowired
    private OptionService optService;

    @ResponseBody
    @RequestMapping("/getOptionsByServiceType")
    public Result getOptionsByType(String serviceType){
        return optService.getOptionsByServiceType(serviceType);
    }

    @ResponseBody
    @RequestMapping("/getOptionInfo")
    public Result getOptionInfo(String optionId ,String serviceId){
        return optService.getOptionInfo(optionId,serviceId);
    }
}
